package cn.openread.starter.utils.excel;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;

/**
 * 表格列对象
 *
 * @author simon
 * @create 2018-09-07 下午5:52
 **/
@Setter
@Getter
@NoArgsConstructor
@ToString
public class ExcelColumn implements Comparable<ExcelColumn> {

    private String columnName;
    private int columnOrder;
    private int columnWidth;
    private int columnHeight;
    private String methodName;
    private boolean columnData;
    private boolean text;

    public ExcelColumn(String columnName, int columnOrder, int columnWidth, int columnHeight, String methodName, boolean columnData, boolean text) {
        this.columnName = columnName;
        this.columnOrder = columnOrder;
        this.columnWidth = columnWidth;
        this.columnHeight = columnHeight;
        this.methodName = methodName;
        this.columnData = columnData;
        this.text = text;
    }

    @Override
    public int compareTo(ExcelColumn o) {
        return Integer.compare(columnOrder, o.getColumnOrder());
    }

}
